﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Estimate.Common.NewReport.DataProvider;
using Estimate.Common.Repository;
using Estimate.Common.Estimate;

namespace Estimate.Common.NewReport.DataProvider
{
    public class IndividualDataProvider : INewReportDataProvider
    {
        public ForeRepository _repository;
        private IndividualSemi _individualSemi;
        private string _forecaster;
        public IndividualDataProvider(string forecaster,ForeRepository repository)
        {
            _repository = repository;
            _individualSemi = new IndividualSemi(_repository.ConnectionString);
            _forecaster = forecaster;
        }

        public Entity.ForeEntity[] InquerySemiWithDateRange(DateTime beginDate, DateTime endDate, DBFieldTypes.ForeClockType[] clocks, DBFieldTypes.ForeSpanType span, DBFieldTypes.ForeSendpointType[] sendpoints, DBFieldTypes.ForeFactorType type, DBFieldTypes.ForeSemiType semitype)
        {
            return _individualSemi.InquerySemiWithDateRange(_repository, _forecaster , beginDate, endDate, clocks, span, sendpoints, type, semitype);
        }
    }
}
